package br.com.guinchomarinho.beans;

import javax.persistence.EntityManager;
import javax.persistence.EntityManagerFactory;
import javax.persistence.Persistence;

public class Valter {
	
	public static void main(String[] args) {
		
		Permissoe p = new Permissoe();
		
		p.setIdpermissoes(1);
		p.setTipospermissoes(2);
		
		EntityManagerFactory emf = Persistence.createEntityManagerFactory("ProjetoGuinchoMarinho");
		EntityManager em = emf.createEntityManager();
		em.getTransaction().begin();
		em.persist(p);
		em.getTransaction().commit();
		em.close();
		emf.close();
		
		
	}
	
}
